﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="tm_newsList.ascx.cs" Inherits="controls_newsList" %>
<center>
    <asp:Panel ID="pnlSearchResult" runat="server" Width="100%">
        <table width="100%">
            <tr>
                <td align="center">
                    <asp:Panel ID="pnlResult" runat="server" Width="100%">
                        <table border="0" width="100%">
                            <tr>
                                <td colspan="3" style="width: 308px">
                                    <asp:Label ID="lblCountRecord" runat="server"></asp:Label></td>
                            </tr>
                            <tr>
                                <td colspan="3">
                                    <asp:GridView ID="gvItemList" runat="server" AllowPaging="True" AllowSorting="True"
                                        AutoGenerateColumns="False" CssClass="table" Width="100%" OnPageIndexChanging="gvItemList_PageIndexChanging" OnSorting="gvItemList_Sorting">
                                        <Columns>
                                            <asp:TemplateField ShowHeader="False">
                                                <ItemTemplate>
                                                    <asp:CheckBox ID="cbxCheck" runat="server" />
                                                    <asp:Label ID="lblNewsId" runat="server" Text='<%# Eval("newsId") %>' Visible="False"></asp:Label>
                                                </ItemTemplate>
                                                <ItemStyle HorizontalAlign="Center" Width="20px" />
                                                <HeaderStyle Width="3%" />
                                            </asp:TemplateField>
                                            <asp:TemplateField HeaderText="Chủ đề" SortExpression="subject">
                                                <EditItemTemplate>
                                                    <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("subject") %>'></asp:TextBox>
                                                </EditItemTemplate>
                                                <ItemTemplate>
                                                    <asp:HyperLink ID="hplSubject" runat="server" NavigateUrl='<%# getLink(DataBinder.Eval(Container, "DataItem.newsId").ToString()) %>' Text='<%# Eval("subject") %>'></asp:HyperLink>
                                                </ItemTemplate>
                                                <HeaderStyle HorizontalAlign="Left" VerticalAlign="Middle" />
                                                <ItemStyle HorizontalAlign="Left" VerticalAlign="Middle" />
                                            </asp:TemplateField>
                                            <asp:BoundField DataField="openDate" DataFormatString="{0:d}" HeaderText="Ng&#224;y"
                                                SortExpression="openDate">
                                                <ItemStyle Width="10%" />
                                            </asp:BoundField>
                                            <asp:BoundField DataField="status" HeaderText="Trạng th&#225;i" SortExpression="status">
                                                <HeaderStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                                                <ItemStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                                            </asp:BoundField>
                                            <asp:BoundField DataField="account" HeaderText="T&#224;i khoản" SortExpression="account">
                                                <ItemStyle HorizontalAlign="Center" />
                                            </asp:BoundField>
                                        </Columns>
                                        <PagerStyle HorizontalAlign="Right" />
                                    </asp:GridView>
                                    <asp:CheckBox ID="cbxCheckAll" runat="server" AutoPostBack="True" CssClass="titletext3" OnCheckedChanged="cbxCheckAll_CheckedChanged" Text="Chọn tất cả" Visible="False" /></td>
                            </tr>
                        </table>
                        <asp:SqlDataSource ID="dsResultSearch" runat="server"></asp:SqlDataSource>
                    </asp:Panel>
                </td>
            </tr>
            <tr>
                <td align="center">
        <asp:Panel ID="pnlBottom" runat="server" Visible="False" Width="100%">
            <table border="0" width="100%">
                <tr>
                    <td align="center" colspan="3">
                        <asp:Label ID="lblMessage" runat="server" CssClass="titletext3"></asp:Label></td>
                </tr>
                <tr>
                    <td colspan="2">
                        <asp:Label ID="lblSetStatus" runat="server" CssClass="titletext3" Text="Trạng thái :"></asp:Label><asp:DropDownList
                            ID="ddlSetStatus" runat="server" AppendDataBoundItems="True">
                        </asp:DropDownList><asp:Button ID="btnAgree" runat="server" CssClass="btn" Text="Đồng ý"
                            Width="80px" OnClick="btnAgree_Click" />
                    </td>
                    <td colspan="1" style="text-align: right;">
                        <asp:Button ID="btnDelete" runat="server" CssClass="btn" Text="Xóa" Width="80px" OnClick="btnDelete_Click" /></td>
                </tr>
            </table>
        </asp:Panel>
                </td>
            </tr>
            <tr>
                <td align="left" class="table">
                    &nbsp;</td>
            </tr>
        </table>
    </asp:Panel>
    </center>
<center>
    </center>
